package com.handydata.antifraud.service.impl;

import com.handydata.antifraud.dao.RiskRuleDictlinfoBasedataDao;
import com.handydata.antifraud.entity.RiskRuleDictIinfoDao;
import com.handydata.antifraud.service.RiskRuleDictInfoService;
import com.handydata.common.exception.SysException;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 操作刷新文件接口
 *
 * @author douhao
 * @email douhao@handy-data.cn
 * @date 2020-06-29 20:51:53
 */
@Service("riskRuleDictInfoService")
public class RiskRuleDictInfoServiceImpl implements RiskRuleDictInfoService {

	@Autowired
	private RiskRuleDictlinfoBasedataDao riskRuleDictlinfoBasedataDao;


	@Override
	public RiskRuleDictIinfoDao queryRiskRuleDictInfoDao(String packageName) throws SysException {
		return riskRuleDictlinfoBasedataDao.queryRiskRuleDictOne(packageName);
	}

	@Override
	public List<RiskRuleDictIinfoDao> queryRiskRuleDictInfoDaoList() throws SysException {
		return riskRuleDictlinfoBasedataDao.queryALL();
	}

	@Override
	public long updateRiskRuleDictInfoDao(RiskRuleDictIinfoDao req) throws SysException {
		return riskRuleDictlinfoBasedataDao.updateRiskRuleDictInfo(req);
	}

	@Override
	public int update1RiskRuleDictInfoDao(String id, RiskRuleDictIinfoDao req) throws SysException {
		return riskRuleDictlinfoBasedataDao.updateRiskRuleDictInfo(req);
	}

	@Override
	public long insertRiskRuleDictInfoDao(RiskRuleDictIinfoDao req) throws SysException {
		return riskRuleDictlinfoBasedataDao.insert(req);
	}
}
